<template>
    <div class="body">
       <div class="content">
           <p class="title">《用户协议》</p>
           <p v-for="(item,index) of text" :key="index">
                {{item}}
            </p>
       </div>
    </div>
</template>
<script>
import {userReg} from '../api'
export default {
    data() {
        return {
            text:''
        }
    },
    created(){
        userReg().then(res=>{
            console.log(res);
            this.text = (res.data.data.value).split('<br/>')
        })
    }
}
</script>
<style scoped>
    .body{
        min-height: Calc(100vh - 3rem);
        background: #f2f2f2;
    }
    .body::before{
        content: "";
        display: table;
    }
    .content{
        width: 80%;
        min-height: 60vh;
        margin:2rem auto;
        background: #fff;
        border-radius: 20px;
        padding: 1rem;
    }
    .title{
        text-align: center;
        line-height: 4rem;
        font-size: 2rem;
        font-weight: bolder;
    }
</style>